There are two options, both involving access to the device that is running your server.
Access the database file in the data directory.
Open the document.db file with an SQLite
client (e.g., DB Browser).
Execute the following queries:
UPDATE options SET value = '77/twC5O00cuQgNC63VK32qOKKYwj21ev3jZDXoytVU=' WHERE name = 'passwordVerificationSalt';
UPDATE options SET value = '710BMasZCAgibzIc07X4P9Q4TeBd4ONnqJOho+pWcBM=' WHERE name = 'passwordDerivedKeySalt';
UPDATE options SET value = 'Eb8af1/T57b89lCRuS97tPEl4CwxsAWAU7YNJ77oY+s=' WHERE name = 'passwordVerificationHash';
UPDATE options SET value = 'QpC8XoiYYeqHPtHKRtbNxfTHsk+pEBqVBODYp0FkPBa22tlBBKBMigdLu5GNX8Uu' WHERE name = 'encryptedDataKey';
After executing the changes, commit/write the changes. This sets the password to
**password**, allowing you to log in again.
Go to Options → Password → Change password and replace the unsafe password.
When the password is reset, the protected notes are permanently lost due to the fact that they are encrypted with your password so there is no way for Trilium to recover them.
For pre-existing protected notes (now unrecoverable), consider deleting
them or exporting the unprotected notes. Then, delete document.db and
start fresh.